﻿using System;
using Shapes;
using UnityEngine;

namespace Gp.Scripts.Core.Misc {
    public class DashOffset : MonoBehaviour {
        private Rectangle _rect;
        public float speed = 1f;

        private void Start() {
            _rect = GetComponent<Rectangle>();
        }

        private void FixedUpdate() {
            if (_rect != null) {
                _rect.DashOffset += speed * Time.deltaTime;
            }
        }
    }
}